package com.hsmpay.mobile.dao.system.impl;

import com.hsmpay.common.dao.Impl.BaseDaoSupport;
import com.hsmpay.mobile.dao.system.HolidaysDao;
import com.hsmpay.mobile.pojo.system.Holidays;
import org.springframework.stereotype.Repository;

import java.sql.SQLException;

/**
 * 节假日dao接口
 * 对应pojo Holidays
 *
 * @author 颜铃璋
 *         创建时间：2014-05-5
 */
@Repository("holidaysDao")
public class HolidaysDaoImpl extends BaseDaoSupport<Holidays, Long> implements HolidaysDao<Holidays, Long> {
    /**
     * 根据日期 查询节假日
     *
     * @param date
     * @param type
     * @return
     * @throws SQLException
     */
    public Holidays searchHolidays(String date, Integer type) throws SQLException {
        Holidays param = new Holidays();
        param.setHDate(date);
        param.setType(type);
        return searchEntity(param);
    }
}
